package com.deyuanyun.pic.pbf.enumeration;

/**
 * 附件中图片 自定义类型
 *
 * @author huanglw
 * @date 2016-7-7
 *
 * History: [修改人][时间][修改描述]
 */
public enum ImgCustomType {

    ALL("不分类型"),
    REPAIR_BEFORE("缺陷维修类型-修复前"),
    REPAIR_DURING("缺陷维修类型-修复中"),
    REPAIR_AFTER("缺陷维修类型-修复后"),
    NDTTYPE("无损检测类型"),
    WELDWORKTYPE("焊接作业指导书"),
    UPLOAD_IMAGE("新增缺陷点照片"),
    APPUPLOAD_IMAGE("app新增缺陷点照片");

    private String label;

    private ImgCustomType(String label){
        this.label = label;
    }

    public String getLabel() {
        return label;
    }

    public void setLabel(String label) {
        this.label = label;
    }

    public static String getLabel(String code) {
        ImgCustomType[] imgCustomTypes = ImgCustomType.values();
        for (int i = 0; i < imgCustomTypes.length; i++) {
            if (imgCustomTypes[i].toString().equals(code)) {
                return imgCustomTypes[i].getLabel();
            }
        }
        return null;
    }
}
